<header class="container-fluid cd-auto-hide-header">
    <div class="container cd-morph-dropdown">
        <h1 class="logo">
            <a href="/" title="{{ webConfig.indexTitle }}">
                <img src="{{ webConfig.logo }}">{{ webConfig.indexTitle }}
            </a>
        </h1>

        <nav id="main-nav" class="hidden-xs hidden-sm">
            <ul class="nav">
                {{ view.r(menuRender('main')) }}
            </ul>
        </nav>
        <div class="right">
            <div class="user-info">
                {% if user.isLogin() %}
                    <a href="{{ url(['for':'userCenterIndex']) }}" class="m-user-face">
                        <img src="{{ user.face }}"/>
                        <span>一叶只秋</span>
                    </a>
                    <a ajax-model="{{ url(['for':'logout']) }}" href="{{ url(['for':'logout']) }}" class="m-user-face">
                        <span>退出</span>
                    </a>
                {% else %}
                    <a ajax-model="{{ url(['for':'login']) }}?rd={{ url }}" href="{{ url(['for':'login']) }}?rd={{ url }}">
                        <span>登录</span>
                    </a>
                    <a ajax-model="{{ url(['for':'register','type':'email']) }}?rd={{ url }}" href="{{ url(['for':'register','type':'email']) }}?rd={{ url }}">
                        <span>注册</span>
                    </a>
                {% endif %}
            </div>
            <a id="phone-user" class="visible-xs-block" href="#"><i class="fa fa-user"></i></a>
            <a href="{{ url(['for':'search']) }}"><i class="fa fa-search"></i></a>
            <a class="visible-xs-block visible-sm-block" id="show-main-menu" href="#"><i class="fa fa-bars"></i></a>
        </div>
    </div>
</header>